home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Pascal Super Library
/
Pascal Super Library (CW International)(1997).bin
/
STRINGS
/
PACKAGE6
/
READCHAR.DOC
< prev
next >
Wrap
Text File
|
1990-07-25
|
1KB
|
38 lines
-----------------------------------------------------------------------------
ReadLnCharacter
-----------------------------------------------------------------------------
declaration: procedure ReadLnCharacter (var Character:
char;
var LastKey:
TypeKey);
purpose: Reads in one character allowing only 'A'..'Z', 'a'..'z'
Enter, Escape, and Backspace.
pre-condition: Character is undefined, LastKey is undefined
post-condition: Character is set to blank if Escape is pressed, and
keeps value if Enter is pressed
special cases: none
example: var Character:
char
var LastKey:
TypeKey;
begin
.
.
.
ReadLnCharacter (Character, LastKey);
if LastKey <> EscapeKey then
write (output, Character);
.
.
.
end;
-----------------------------------------------------------------------------